urlaccesssimpletransfer.htmlHTMLudogBÖπùΔ§πùΔ§ÅÅÄt Monkeybread Realbasic plugin - Documentation - URLAccessSimpleTransfer

MBS Plugin Documentation

This is the documentation for the Realbasic Plugins from Monkeybreadsoftware.de. You find these plugins and the newest version of this document at http://www.monkeybreadsoftware.de/realbasic inside the plugins section.

This help was last updated on Freitag, 6. September 2002 and covers 2136 items: 126 classes, 2 controls and 583 global functions.

The list of the themes Global methods by category Global methods by name The list of the classes The list of the controls

class URLAccessSimpleTransfer

class, URLAccess Mi, 4. Sep 2002
Mac OS Classic: Works. Mac OS Carbon: Works. Windows: does nothing.
Function: A simple URLAccess download.
Notes: Requires URLAccess extension.

DirectoryListing as boolean

property, URLAccess Mi, 4. Sep 2002
Mac OS Classic: Works. Mac OS Carbon: Works. Windows: does nothing.
Function: Return directory listing?

DisplayAuth as boolean

property, URLAccess Mi, 4. Sep 2002
Mac OS Classic: Works. Mac OS Carbon: Works. Windows: does nothing.
Function: Display an authorisation box?
Notes: The URL may contain a username and a password.

DisplayProgress as boolean

property, URLAccess Mi, 4. Sep 2002
Mac OS Classic: Works. Mac OS Carbon: Works. Windows: does nothing.
Function: Display an progress bar dialog?

DoNotTryAnonymous as boolean

property, URLAccess Mi, 4. Sep 2002
Mac OS Classic: Works. Mac OS Carbon: Works. Windows: does nothing.
Function: Do not try anonymous?
Notes: The URL may contain a username and a password.

Download

method, URLAccess Mi, 4. Sep 2002
Mac OS Classic: Works. Mac OS Carbon: Works. Windows: does nothing.
Function: Downloads a file.
Notes:
The property URL is used for the URL to the file you want to download.

File is a folderitem that identifies the file or directory into which data is to be downloaded. If you wish to download data into memory, pass nil in this parameter and the data will be put into the result property. If you pass a folderitem that does not identify a file or directory, the name of the file or directory specified by the pathname in the url parameter is used. If you pass a file or directory that already exists, and do ReplaceExisting is false, URLSimpleDownload creates a new file or directory whose name has a number appended before the extension. For example, if the URL specifies a file named file.txt, URLSimpleDownload changes the filename to file1.txt.

This function does not return until the download is complete.
See the lasterror property for the error code returned.

When Download downloads data from a URL that represents a local file (that is, a URL that begins with file:///), the data fork is downloaded but the resource fork is not.

In Mac OS 8.6, if the file type of the file to be downloaded is unknown, Download assumes that the file is of type text. In this case, the end-of-line character is changed to the Mac style end-of-line character 0x0d0x0a. In Mac OS 9, when a file of unknown type is downloaded, Download does not assume that it is a text file. Instead, it identifies it as an unknown file type and does not change the end-of-line character.

Supported in Carbon. Available in Carbon 1.0.2 and later when running Mac OS 8.1 or later.

ExpandAndVerify as boolean

property, URLAccess Mi, 4. Sep 2002
Mac OS Classic: Works. Mac OS Carbon: Works. Windows: does nothing.
Function: Expand and verify?
Notes: Using Stuffit Expander.

ExpandFile as boolean

property, URLAccess Mi, 4. Sep 2002
Mac OS Classic: Works. Mac OS Carbon: Works. Windows: does nothing.
Function: Expand file?
Notes: Using Stuffit Expander.

File as folderitem

property, URLAccess Mi, 4. Sep 2002
Mac OS Classic: Works. Mac OS Carbon: Works. Windows: Allways 0.
Function: A reference to a file or folder.

IsDirectoryHint as boolean

property, URLAccess Mi, 4. Sep 2002
Mac OS Classic: Works. Mac OS Carbon: Works. Windows: does nothing.
Function: Exspect a directory?

LastError as integer

property, URLAccess Mi, 4. Sep 2002
Mac OS Classic: Works. Mac OS Carbon: Works. Windows: Allways 0.
Function: The last error code.
Notes:
Lasterror may have any Mac OS error code, but the functions return -1 if the URLAccess library is not available.

Possible URLAccess error codes:

InvalidURLReferenceError -30770
ProgressAlreadyDisplayedError -30771
DestinationExistsError -30772
InvalidURLError -30773
UnsupportedSchemeError -30774
ServerBusyError -30775
AuthenticationError -30776
PropertyNotYetKnownError -30777
UnknownPropertyError -30778
PropertyBufferTooSmallError -30779
UnsettablePropertyError -30780
InvalidCallError -30781
FileEmptyError -30783
ExtensionFailureError -30785
InvalidConfigurationError -30786
AccessNotAvailableError -30787
68kNotSupportedError -30788

ReplaceExisting as boolean

property, URLAccess Mi, 4. Sep 2002
Mac OS Classic: Works. Mac OS Carbon: Works. Windows: does nothing.
Function: Replace existing file?

Result as string

property, URLAccess Mi, 4. Sep 2002
Mac OS Classic: Works. Mac OS Carbon: Works. Windows: Allways 0.
Function: If you downloaded to memory, the file content is in this string.

Upload

method, URLAccess Mi, 4. Sep 2002
Mac OS Classic: Works. Mac OS Carbon: Works. Windows: does nothing.
Function: Uploads a file.
Notes:
The property URL represents the URL to which a file or directory is to be uploaded. If you wish to replace the destination directory of this URL with the file or directory that you pass in the source parameter, terminate the string with a slash character (/), and set ReplaceExisting=true. If you specify a name that already exists on the server and do not specify ReplaceExisting=True, Upload returns the result code kURLDestinationExistsError (-30772) in the lasterror property. If you do not specify a name, do not specify ReplaceExistingFlag=true, and the name already exists on the server, the URL Access Manager creates a unique name by appending a number to the original name before the extension, if any. For example, if the URL specifies a file named file.txt, URLSimpleUpload changes the filename to file1.txt.

This function does not return until the upload is complete.
See the lasterror property for the error code returned.

When Download downloads data from a URL that represents a local file (that is, a URL that begins with file:///), the data fork is downloaded but the resource fork is not.

In Mac OS 8.6, if the file type of the file to be uploaded is unknown, Upload assumes that the file is of type text. In this case, the end-of-line character is changed to the Mac style end-of-line character 0x0d0x0a. In Mac OS 9, when a file of unknown type is uploaded, Upload does not assume that it is a text file. Instead, it identifies it as an unknown file type and does not change the end-of-line character.

Supported in Carbon. Available in Carbon 1.0.2 and later when running Mac OS 8.1 or later.

URL as string

property, URLAccess Mi, 4. Sep 2002
Mac OS Classic: Works. Mac OS Carbon: Works. Windows: Allways 0.
Function: An URL string.

Contact

Written 2002 by Christian Schmitz. Feel free to ask or report mistakes to realbasic@macsw.de.
Thanks.

This resource fork intentionally left blank ˇˇ